import { defineStore } from "pinia";
import { getInfo } from "@/api/manager.js";
export const useAdminStore = defineStore("admin", {
  state: () => {
    return {
      adminInfo: {},
    };
  },
  actions: {
    getAdminInfo() {
      return getInfo()
        .then((res) => {
          console.log(1111);
          this.adminInfo = res;
          console.log(this.adminInfo);
        })
        .catch((err) => {
          console.log(err);
        });
    },
  },
});
